package cn.tianjindong.blog.mapper;

import cn.tianjindong.blog.pojo.BlogNotice;
import cn.tianjindong.blog.pojo.BlogNoticeExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface BlogNoticeMapper {
    int countByExample(BlogNoticeExample example);

    int deleteByExample(BlogNoticeExample example);

    int deleteByPrimaryKey(Long id);

    int insert(BlogNotice record);

    int insertSelective(BlogNotice record);

    /**
     * 进行分页查询
     * @param startIndex
     * @param countItem
     * @return
     */
	List<BlogNotice> getNoticeListLimit(int startIndex, Integer countItem);
    
	 /**
     * 进行分页查询,只查询tab==1的公告，此方法通常用于前台公告展示
     * @param startIndex
     * @param countItem
     * @return
     */
	List<BlogNotice> getNoticeListLimitAndTab(int startIndex, Integer countItem);
    List<BlogNotice> selectByExampleWithBLOBs(BlogNoticeExample example);

    List<BlogNotice> selectByExample(BlogNoticeExample example);

    BlogNotice selectByPrimaryKey(Long id);

    int updateByExampleSelective(@Param("record") BlogNotice record, @Param("example") BlogNoticeExample example);

    int updateByExampleWithBLOBs(@Param("record") BlogNotice record, @Param("example") BlogNoticeExample example);

    int updateByExample(@Param("record") BlogNotice record, @Param("example") BlogNoticeExample example);

    int updateByPrimaryKeySelective(BlogNotice record);

    int updateByPrimaryKeyWithBLOBs(BlogNotice record);

    int updateByPrimaryKey(BlogNotice record);

}